<template>
  <!-- 整个页面的外层容器 -->
  <el-container>
    <!-- 顶栏 -->
    <el-header class="layout-header">
      <!--顶栏-->
      <h1>鄂食汇</h1>
      <el-menu
          :default-active="activeIndex2"
          class="el-menu-demo"
          mode="horizontal"
          @select="handleSelect"
          background-color="#FFDE68FF"
          text-color="#fff"
          active-text-color="#409eff">
        <el-menu-item index="1">首页</el-menu-item>
        <el-submenu index="2">
          <template slot="title">美食特产</template>
          <el-menu-item index="2-1">选项1</el-menu-item>
          <el-menu-item index="2-2">选项2</el-menu-item>
          <el-menu-item index="2-3">选项3</el-menu-item>
          <el-submenu index="2-4">
            <template slot="title">选项4</template>
            <el-menu-item index="2-4-1">选项1</el-menu-item>
            <el-menu-item index="2-4-2">选项2</el-menu-item>
            <el-menu-item index="2-4-3">选项3</el-menu-item>
          </el-submenu>
        </el-submenu>
        <el-submenu index="3">
          <template slot="title">菜谱大全</template>
          <el-menu-item index="2-1">选项1</el-menu-item>
          <el-menu-item index="2-2">选项2</el-menu-item>
          <el-menu-item index="2-3">选项3</el-menu-item>
          <el-submenu index="2-4">
            <template slot="title">选项4</template>
            <el-menu-item index="2-4-1">选项1</el-menu-item>
            <el-menu-item index="2-4-2">选项2</el-menu-item>
            <el-menu-item index="2-4-3">选项3</el-menu-item>
          </el-submenu>
        </el-submenu>

        <el-submenu index="4">
          <template slot="title">问答</template>
          <el-menu-item index="2-1">选项1</el-menu-item>
          <el-menu-item index="2-2">选项2</el-menu-item>
          <el-menu-item index="2-3">选项3</el-menu-item>
          <el-submenu index="2-4">
            <template slot="title">选项4</template>
            <el-menu-item index="2-4-1">选项1</el-menu-item>
            <el-menu-item index="2-4-2">选项2</el-menu-item>
            <el-menu-item index="2-4-3">选项3</el-menu-item>
          </el-submenu>
        </el-submenu>
        <el-menu-item index="5"><a href="https://www.ele.me" target="_blank">地图索引</a></el-menu-item>
      </el-menu>
    </el-header>
    <el-main>
        <div style="width: 500px">
          <el-carousel height="150px">
            <el-carousel-item>
              <img src="public/imgs/b1.jpg" width="100%" height="100%">
            </el-carousel-item>
            <el-carousel-item>
              <img src="public/imgs/b2.jpg" width="100%" height="100%">
            </el-carousel-item>
            <el-carousel-item>
              <img src="public/imgs/b3.jpg" width="100%" height="100%">
            </el-carousel-item>
          </el-carousel>
        </div>
      <el-row>
        <!--el-col表示一列 一行最多24分栏-->
        <el-col span="12" style="">
          <div class="c1">123</div></el-col>
        <el-col span="12">
          <div class="c1" style="background: rgba(40,40,40,0.21)">456</div></el-col>
      </el-row>
    </el-main>
    <el-footer>Footer</el-footer>
  </el-container>
</template>

<style>
.el-header {
  background-color: #fff7db;
  color: #959595;
  text-align: center;
  line-height: 60px;
  padding: 0;
}
.el-footer {
    background-color: #282828;
    color: #ffffff;
    text-align: center;
    line-height: 60px;
  }

.el-aside {
  background-color: #D3DCE6;
  color: #333;
  text-align: center;
  line-height: 200px;
}

.el-main {
  background-color: #ffffff;
  color: #333;
  text-align: center;
  line-height: 900px;
}

body > .el-container {
  margin-bottom: 40px;
}

.el-container:nth-child(5) .el-aside,
.el-container:nth-child(6) .el-aside {
  line-height: 260px;
}

.el-container:nth-child(7) .el-aside {
  line-height: 320px;
}

</style>